package cn.fufeiii.bt.common.code;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 公共的结果枚举
 *
 * @author FuFei
 */
@AllArgsConstructor
@Getter
public enum CommonResultEnum implements ResultDefinition {

    SERVER_SUCCESS(1000, "SUCCESS"),
    SERVER_FAIL(1001, "FAIL"),

    REQUEST_ABNORMALITY(4001, "客户端请求异常"),
    ;

    private final Integer code;
    private final String message;

    @Override
    public Integer getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }
}
